package org.goldenport.g3.events

import org.goldenport.g3.{G3Command, G3Event}
import org.goldenport.g3.messages._
import org.goldenport.g3.messages.RecordSet

/**
 * @since   Sep.  8, 2010
 * @version Oct. 10, 2010
 * @author  ASAMI, Tomoharu
 */
abstract class RecordFetched(
  uri: String,
  val command: G3Command,
  val records: RecordSet,
  val single: Boolean = true,
  cause: Option[G3Event] = None
) extends Getted(uri, Some(records), cause)

abstract class RecordQueried(
  uri: String,
  val command: G3Command,
  val records: RecordSet,
  cause: Option[G3Event] = None
) extends Getted(uri, Some(records), cause)

abstract class RecordInserted(
  uri: String,
  val command: G3Command,
  val records: RecordSet,
  cause: Option[G3Event] = None
) extends Posted(uri, Some(records), cause)

abstract class RecordUpdated(
  uri: String,
  val command: G3Command,
  val records: RecordSet,
  cause: Option[G3Event] = None
) extends Putted(uri, Some(records), cause)

abstract class RecordDeleted(
  uri: String,
  val command: G3Command,
  cause: Option[G3Event] = None
) extends Deleted(uri, cause)
